#include "syscall.h"
#include "user.h"

void main()
{
	int firstLock;
	int secondLock;
	int firstCV;
	firstLock = rpcCreateLock("wuyuzhe",sizeof("wuyuzhe"));
	secondLock = rpcCreateLock("weiqiaosong",sizeof("weiqiaosong"));
	firstCV = rpcCreateCondition("qiaoge",sizeof("qiaoge"));
	rpcAcquireLock(firstLock);
	Printf("Now I am trying to Acquire the second lock which owned by the inactive Socket\n");
	rpcAcquireLock(secondLock);
	rpcReleaseLock(firstLock);
	rpcReleaseLock(secondLock);

	Printf("If you see this, congratulations!\n");
	Halt();
}